home *** CD-ROM | disk | FTP | other *** search
- Path: news.cs.hope.edu!vnopstal
- From: vnopstal@cs.hope.edu (Michael Van Opstall)
- Newsgroups: comp.lang.c++
- Subject: [Q] Pointers to multi-D arrays
- Date: 12 Jan 1996 00:40:19 GMT
- Organization: Hope College
- Message-ID: <4d4alj$5o8@news.cs.hope.edu>
- NNTP-Posting-Host: smaug.cs.hope.edu
- X-Newsreader: TIN [version 1.2 PL2]
-
- How do you make a pointer to a multi dimensional array?
-
- I have this:
-
- Complex* data;
- // in the header
- ...
- // the constructor...
- data=new Complex[v][h];
-
- and I get an error because it's trying to make an array of pointers to
- arrays of Complex instead of one pointer to a larger array.
-
- TIA
- --
- Michael A. Van Opstall -- vnopstal@cs.hope.edu
- http://www.cs.hope.edu/~vnopstal/deal.html - try it
-